Now let's try drawing a rectangle instead:
1: <-- File: GraphicsApplet.html >
2:
3:
4: GraphicsApplet
5:
6:
7:
12:
13:
Here's an example that draws the string "Applets are forever" in a purple color:
1: <-- File: GraphicsApplet.html >
2:
3:
4: GraphicsApplet
5:
6:
7:
13:
14:
Finally, let's try an example that draws an image of the friendly HotJava mascot, Duke:
1: <-- File: GraphicsApplet.html >
2:
3:
4: GraphicsApplet
5:
6:
7:
12:
13: